package cn.ibobo.lease.admin.service.impl;

import cn.ibobo.lease.common.base.BaseMapper;
import cn.ibobo.lease.common.base.BaseServiceImpl;
import cn.ibobo.lease.admin.dao.AdminRoleMapper;
import cn.ibobo.lease.admin.dto.AdminRoleDTO;
import cn.ibobo.lease.admin.service.AdminRoleService;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.transaction.annotation.Transactional;
import org.springframework.stereotype.Service;
import java.util.List;


/**
 * 管理员角色表业务处理接口
 * @Author lililiang
 * @Date 2018-12-13 18:38:03
 */
@Service
public class AdminRoleServiceImpl extends BaseServiceImpl<AdminRoleDTO, String> implements AdminRoleService {

    private static final Log LOGGER = LogFactory.getLog(AdminRoleServiceImpl.class);

    @Autowired
    private AdminRoleMapper mapper;

    @Override
    protected BaseMapper<AdminRoleDTO, String> getMapper() {
        return mapper;
    }

    /**
     * 管理员角色表列表
     * @Author lililiang
     * @Date 2018-12-13 18:38:03
     * @Param
     * @Return
     */
    @Override
    public List<AdminRoleDTO> list4Page(AdminRoleDTO entity, Integer pageNum, Integer... pageSize) {
        return super.list4Page(entity, pageNum, pageSize);
    }

    /**
     * 管理员角色表列表（无分页）
     * @Author lililiang
     * @Date 2018-12-13 18:38:03
     * @Param
     * @Return
     */
    @Override
    public List<AdminRoleDTO> listByCondition(AdminRoleDTO entity) {
        return super.listByCondition(entity);
    }

    /**
     * 查询管理员角色表详情信息
     * @Author lililiang
     * @Date 2018-12-13 18:38:03
     * @Param
     * @Return
     */
    @Override
    public AdminRoleDTO queryOneByPk(String id) {
        return super.queryOneByPk(id);
    }

    /**
     * 保存管理员角色表信息
     * @Author lililiang
     * @Date 2018-12-13 18:38:03
     * @Param
     * @Return
     */
    @Override
    @Transactional
    public Integer save(AdminRoleDTO entity) {
        return super.save(entity);
    }

    /**
     * 删除管理员角色表信息
     * @Author lililiang
     * @Date 2018-12-13 18:38:03
     * @Param
     * @Return
     */
    @Override
    @Transactional
    public Integer delete(String id) {
        return super.delete(id);
    }
}
